/*
CREATE TABLE "base_rule_details_full" (
  "sequence_nbr" text(20),
  "library_code" text(255),
  "relation_group_code" text(255),
  "kind" text(255),
  "relation_group_id" text(255),
  "relation_group_name" text(255),
  "relation_group_cnt" integer(11),
  "relation_group_rule" text(255),
  "file_details_id" text(20),
  "relation_code" text(255),
  "relation" text(255),
  "math" text(255),
  "de_id" text(18),
  "de_code" text(255),
  "de_name" text(255),
  "default_value" real(16,6),
  "default_value_max" text(255),
  "default_value_min" text(255),
  "rule_range" text(255),
  "relation_de_code" text(255),
  "relation_de_id" text(18),
  "data_format" integer(11),
  "sort_no" integer(18),
  "type" text(255),
  "rec_user_code" text(255),
  "rec_status" text(255),
  "rec_date" text(255),
  "extend1" text(255),
  "extend2" text(255),
  "extend3" text(255),
  "description" text(255),
  "agency_code" text(255),
  "product_code" text(255),
  "top_group_type" text(255),
  "rcj_id" text(18),
  "sort_no_global" integer(11)
);
*/

use rbatis::crud;
use serde::{Deserialize, Serialize};

#[derive(Debug, Serialize, Deserialize)]
pub struct BaseRuleDetailsFull {
    pub sequence_nbr: String,
    pub library_code: Option<String>,
    pub relation_group_code: Option<String>,
    pub kind: Option<String>,
    pub relation_group_id: Option<String>,
    pub relation_group_name: Option<String>,
    pub relation_group_cnt: Option<i32>,
    pub relation_group_rule: Option<String>,
    pub file_details_id: Option<String>,
    pub relation_code: Option<String>,
    pub relation: Option<String>,
    pub math: Option<String>,
    pub de_id: Option<String>,
    pub de_code: Option<String>,
    pub de_name: Option<String>,
    pub default_value: Option<f64>,
    pub default_value_max: Option<String>,
    pub default_value_min: Option<String>,
    pub rule_range: Option<String>,
    pub relation_de_code: Option<String>,
    pub relation_de_id: Option<String>,
    pub data_format: Option<i32>,
    pub sort_no: Option<i32>,
    pub r#type: Option<String>,
    pub rec_status: Option<String>,
    pub rec_date: Option<String>,
    pub extend1: Option<String>,
    pub extend2: Option<String>,
    pub extend3: Option<String>,
    pub description: Option<String>,
    pub agency_code: Option<String>,
    pub product_code: Option<String>,
    pub top_group_type: Option<String>,
    pub rcj_id: Option<String>,
    pub sort_no_global: Option<i32>,
}
crud!(BaseRuleDetailsFull {}, "base_rule_details_full");
